<template>
  <div id="user_info">
    
  </div>
</template>
<script>
export default {
  data() {
    return {
      login_state: '',
      username: '',
    }
  },
  computed: {
    logState() {
      return this.$store.state.mutations.logState
    }
  },
  beforeRouteEnter(to, from, next) {
    next(vm => {
      // if (vm.logState) {
      //   vm.$router.push('/user_info')
      // } else {
      //   vm.$router.push('/login')
      // }
      // if (to.path == '/user_info') {
      //   vm.$store.dispatch('hideheader')
      // } else {
      //   vm.$store.dispatch('showheader')
      // }
    })
  },
  created() {
    // this.$store.dispatch('login');
    // if (sessionStorage.getItem('user')) {
    //   this.username = JSON.parse(sessionStorage.getItem('user')).username;
    // }
  },
  methods: {
    exit() {
      var that = this;
      // var formdata = new FormData();
      // formdata.append('username', '')
      // that.$http({
      //   url: '/sessions_user',
      //   method: 'post',
      //   data: formdata
      // }).then((res) => {
      //   console.log(res.data);
      //   if (res.data == 'exit') {
      //     sessionStorage.clear('user')
      //     that.$store.dispatch('login');
      //     that.$router.push('/login');
      //   } else {
      //     mui.toast('退出失败', { duration: '1000', type: 'div' })
      //   }
      // })
    }
  }
}
</script>

<style scoped>
#user_info {
  /* margin-top:42px; */
  margin-bottom: 55px;
}

.mui-content .bj .img1 {
  width: 100%;
}

.mui-content .bj {
  position: relative;
}

.mui-content .bj .img2 {
  position: absolute;
  top: 50%;
  left: 50%;
  margin-top: -50px;
  margin-left: -40px;
  border-radius: 100%;
  width: 80px;
  height: 80px;
}

.mui-content .bj p {
  position: absolute;
}

.mui-content .bj p:nth-child(3) {
  top: 70%;
  color: #fff;
  width: 100%;
  text-align: center;
  font-size: 15px;
}

.mui-content .bj p:nth-child(4) {
  top: 80%;
  color: #b9aeae;
  width: 100%;
  text-align: center;
  font-size: 13px;
}

section {
  display: flex;
  text-align: center;
  width: 100%;
  padding: 6px 0;
  margin: 6px 0;
  background-color: #fff;
}

.Gongge {
  width: 100%;
  flex: 1;
}

.Gongge a {
  width: 100%;
  display: block;
  padding: 6px 0;
}

.Gongge img {
  width: 32px;
}

.Gongge p {
  font-size: 14px;
  margin: 6px 0;
  color: #353333;
}

ul>li img {
  width: 26px;
  height: 26px;
  vertical-align: middle;
}

ul>li span {
  vertical-align: sub;
  margin-left: 12px;
  font-size: 15px;
}
</style>

